<template>
  <div>
    <p>Child</p>
    <p>{{ value }}</p>
    <button @click="handleClick">按钮</button>
  </div>
</template>

<script>
export default {
  name: "XChild",
  props: {
    value: Number,
  },
  methods: {
    handleClick() {
      this.$emit("input", this.value + 1);
    },
  },
};
</script>

<style></style>
